/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package length;

import rule.Rule;
import score.Score;

/**
 *
 * @author Daniel Gribel
 */
public class Length02 extends Length {
    
    private static final int SCORE_CONST = 4;
    
    public Length02(Score score) {
        this.setScore(score);
    }
    
    @Override
    public void calculate(String dataEntry) {
        setLength(dataEntry.length());
        getScore().applyScore(getLength() * SCORE_CONST);
    }

}
